home *** CD-ROM | disk | FTP | other *** search
- ATARI MACHINE SPECIFIC LIBRARY
-
-
-
- NAME
- Termination - taking control of hardware termination
-
- SYNOPSIS
- #include <Termination.h>
-
- void TrapExceptions(bool on)
-
- DESCRIPTION
- Fiddling with graphics, colours, mouse vectors, etc. can leave the
- computer in a bad state if you don't clean up properly. So we should
- always clean up... but what about while we are developing software and
- we get a bomb? This module supports clean up for this case.
-
- FUNCTIONS
- void TrapExceptions(bool on)
- on=TRUE -> Trap all exceptions.
- on=FALSE -> Just let it bomb (default).
-
- EXAMPLES
- The AMS Library already uses this facility so that even with a crash:
- - The Screen display and colours are restored
- - The Resolution is restored
- - Mouse and joysticks are restored (ie. mouse is enabled)
- - The Timer A is halted
-
- SEE ALSO
- signal.h
-
- DIAGNOSTICS
- The return value of a program that crashes and recovers because of
- the features of this module will exit with a return value equal to
- the signal number of the exception.
-
- BUGS
- This module uses very low-level code to handle hardware exceptions
- that may not be valid on machines other than the ST. But if it
- works on the TT, then use it - it's better than leaving the machine
- with the screen Physbase not equal to Logbase! It should perhaps
- not be used in a production release - but that shouldn't bomb!
-
- AUTHOR
- Warwick Allison, 1992.
- warwick@cs.uq.oz.au
-
- COPYING
- This functionality is part of the Atari Machine Specific Library,
- and is Copyright 1992 by Warwick W. Allison.
-
- The Atari Machine Specific Library is free and protected under the
- GNU Library General Public License.
-
- You are free to copy and modify these sources, provided you acknowledge
- the origin by retaining this notice, and adhere to the conditions
- described in the GNU LGPL.
-